<!-- 申报成功弹窗 -->
<template>
    <Modal :value="value" width="746" @input="handleInput" class="col-2" class-name="no-border" :closable="false" footer-hide>
        <div slot="header">
            发送报关单
            <Icon class="f-fr" type="ios-close" @click="closeModal"/>
        </div>
        <div class="clearfix">
            <div class="f-fl icon">
                <Icon type="ios-checkmark-circle"/>
            </div>
            <div class="f-fl modal-content" style="width: 600px; height: 80px">
                {{ sendAllText }}
            </div>
        </div>
    </Modal>
</template>

<script>
export default {
    name: 'DeclareSuccessModal',
    props: {
        value: {
            default: false,
            type: Boolean
        },
        declareSuccess: {
            default: function () {
                return {
                    sendAllText: ''
                }
            },
            type: Object
        }
    },
    created () {
        this.init(this.declareSuccess.sendAllText)
    },
    data () {
        return {
            sendAllText: ''
        }
    },
    methods: {
        init (sendAllText) {
            this.sendAllText = sendAllText
        },
        closeModal () {
            this.handleInput(false)
        },
        handleInput (v) {
            this.$emit('input', v)
        }
    }
}
</script>
